package com.hqyj.pojo;

import com.baomidou.mybatisplus.annotation.IdType;

import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Date;
import com.baomidou.mybatisplus.annotation.TableId;
import java.io.Serializable;
import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * <p>
 * 退货记录
 * </p>
 *
 * @author rock
 * @since 2021-10-21
 */
@Data
@EqualsAndHashCode(callSuper = false)
public class Tuihuo extends Page implements Serializable {

    private static final long serialVersionUID=1L;

    @TableId(value = "tuihuo_id", type = IdType.AUTO)
    private Integer tuihuoId;

    private Integer sysId;

    private Integer purchaseId;

    private Date tuihuoTime;

    public String  getTuihuoTime() {
        SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");

        return sdf.format(this.tuihuoTime);
    }

    public void setTuihuoTime(String tuihuoTime) {
        SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");

        try {
            this.tuihuoTime = sdf.parse(tuihuoTime);
        } catch (ParseException e) {
            e.printStackTrace();
        }
    }
}
